package ch16;

/**
 * Created by zhangyunqi on 2017/10/22.
 */

public interface BinaryTree<T> extends Iterable <T> {
    public T getRootElement();

    public BinaryTree <T> getLeft();

    public BinaryTree <T> getRight();

    public boolean contains(T target);

    public T find(T target);

    public boolean isEmpty();

    public int size();

    public String toString();

    public Iterable <T> preorder(BTNode <T> right);

    public Iterable <T> inorder();

    public Iterable <T> postorder();

    public Iterable <T> levelorder();


}
